﻿using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class BagSingleTon 
{
    #region  单例
    public static readonly BagSingleTon instance = new BagSingleTon();
    private BagSingleTon() { }
    #endregion


    //equip: 子对象装备    box： 父对象格子
    public void SetEquipToBox(Transform equip , Transform box)
    {
        //设置新的父物体
        equip.SetParent(box);

        //设置本地坐标
        equip.localPosition = Vector3.zero;

        //更新父物体标记
        equip.GetComponent<EquipItem>().parent = box;

    }
   


}
